<%@ page import="java.util.List" %>
<%@ page import="Hbase.Encapsulation" %>
<%@ page isELIgnored="false"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>


<html>
<head>
    <title>Total Information</title>
    <link rel="stylesheet" href="https://cdn.staticfile.org/twitter-bootstrap/3.3.7/css/bootstrap.min.css">
    <style type="text/css">
        table,table tr th, table tr td {
            border:1px solid #a8aeb2;
            padding: 5px 10px;
        }
        table {
            min-height: 25px;
            line-height: 25px;
            text-align: center;
            border-collapse: collapse;
        }

        <!--表格-->
        @import url('https://fonts.googleapis.com/css?family=Roboto:100,100i,300,300i,400,400i,500,500i,700,700i,900,900i');

        /*----------------------------------------------------------
        GENERAL
        ----------------------------------------------------------*/
        *{
            margin:0;
            padding:0;
            font-family: 'Roboto', sans-serif;
        }

        html, body{
            display:table;
            height:100%;
            width:100%;
            color: #252a3b;
            background-color: #e4b9c0;
        }
        .row__title{
            color: #53646f;
            font-weight: 400;
            font-size: 20px;
            margin: 0;
        }

        .row--top-40{
            margin-top: 40px;
        }

        .row--top-20{
            margin-top: 20px;
        }
        .table__th {
            color: #9eabb4;
            font-weight: 500;
            font-size: 12px;
            cursor: pointer;
            border:0 !important;
            padding: 15px 8px !important;
        }

        .table-row {
            border-bottom: 1px solid #e4e9ea;
            background-color: #fff;
        }

        .table-row__td {
            padding: 12px 8px !important;
            vertical-align: middle !important;
            color: #53646f;
            font-size: 13px;
            font-weight: 400;
            position:relative;
            line-height: 18px !important;
            border:0 !important;
        }



        .table-row__info {
            display: inline-block;
            padding-left: 12px;
            vertical-align: middle;
        }

        .table-row__name {
            color: #53646f;
            font-size: 14px;
            font-weight: 400;
            line-height: 18px;
            margin-bottom: 0px;
        }


        .table-row--red {
            background-color: #fff2f2;
        }

        @media screen and (max-width: 991px){
            .table__thead {
                display: none;
            }
            .table-row {
                display: inline-block;
                border: 0;
                background-color: #fff;
                width: calc(33.3% - 13px);
                margin-right: 10px;
                margin-bottom: 10px;
            }

            .table-row__td:before{
                content:attr(data-column);
                color: #9eabb4;
                font-weight: 500;
                font-size: 12px;
                text-transform: uppercase;
                display: block;
            }



            .table-row__td {
                display: block;
                text-align: center;
                padding: 8px !important;
            }
            .table-row--red {
                background-color: #ebcccc;
            }

        }


        @media screen and (max-width: 680px){
            .table-row {
                width: calc(50% - 13px);
            }
        }

        @media screen and (max-width: 480px){
            .table-row {
                width: 100%;
            }
        }
    </style>
</head>
<body>
<div class="container">
    <div class="row row--top-40">
        <div class="col-md-12">
    <h1  style="text-align: center;font-size: 50px" class="lead">Table Information</h1>
        </div>
    </div>
    <div class="row row--top-20">
        <div class="col-md-12">
            <div class="table-container">
                <table class="table" align="center">
                    <tbody class="table-tbody">
                    <thead class="table__thead">

            <tr>

                <td data-title="" class="table-th">Name</td>
                <td data-title="" class="table-th">ID</td>
                <td data-title="" class="table-th">Data</td>
                <td data-title="" class="table-th">Number</td>
                <td data-title="" class="table-th">Status</td>
                <td data-title="" class="table-th">Term</td>
                <td data-title="" class="table-th">Operate</td>

            </tr>
                    </thead>

            <c:forEach items="${Student}" var="commodity">
                <tr  class="table-row table-row--natalie table-row--red">
                    <td  class="table-row__td table-row__name">${commodity.getName()}</td>
                    <td  class="table-row__td table-row__name">${commodity.getId()}</td>
                    <td  class="table-row__td table-row__name">${commodity.getData()}</td>
                    <td  class="table-row__td table-row__name">${commodity.getNumber()}</td>
                    <td  class="table-row__td table-row__name">${commodity.getStatus()}</td>
                    <td  class="table-row__td table-row__name">${commodity.getTerm()}</td>

                    <td>
                        <button type="button" ><a href="UpdateStudent.jsp">编辑</a></button>
                        <button type="button" onclick="nihao()"><a href=" <%=request.getContextPath()%>/deleterow?row=${commodity.getId()}"> 删除 </a></button>
                    </td>

                </tr>

            </c:forEach>
                 <div style="text-align: center">
                    <button type="button" class="btn btn-secondary btn-lg" >学生信息录入</button>
                    <button type="button" style="margin-left: 20px" class="btn btn-secondary btn-lg" >学生信息查询</button>
                    <button type="button" style="margin-left: 20px" class="btn btn-secondary btn-lg" >上传/下载</button>

                 </div>
                    <br>

                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>

<button type="button" style="margin-left: 700px" class="btn btn-secondary btn-lg" ><a href="UpdateStudent.jsp">添加信息</a></button>

        <script>

        function  nihao(){
            alert("确定删除？");
            window.history.back(-1);
        }
       </script>
</body>
</html>
